import * as network from '@/utils/request';

import { cabinet } from '../../config/Apis';


export async function getCabinetList(params: any): Promise<any> {
    return network.post(cabinet.cabinetList, {
        data: params,
        requestType: 'form'
    });
}

export async function findByName(params: any): Promise<any> {
    return network.post(cabinet.findByName, {
        data: params,
        requestType: 'form'
    });
}

export async function getCabinetTariff(params: any): Promise<any> {
    return network.post(cabinet.cabinetTariff, {
        data: params,
        requestType: 'form'
    });
}

export async function getCabinetDetail(params: any): Promise<any> {
    return network.post(cabinet.cabinetDetail, {
        data: params,
        requestType: 'form'
    });
}

export async function CabinetCreate(params: any): Promise<any> {
    return network.post(cabinet.cabinetCreate, {
        data: params,
        requestType: 'form'
    });
}

export async function CabinetUpdate(params: any): Promise<any> {
    return network.post(cabinet.cabinetUpdate, {
        data: params,
        requestType: 'form'
    });
}

export async function CabinetDelete(params: any): Promise<any> {
    return network.post(cabinet.cabinetDelete, {
        data: params,
        requestType: 'form'
    });
}

export async function CabinetCellByCab(params: any): Promise<any> {
    return network.post(cabinet.cabinetCellByCab, {
        data: params,
        requestType: 'form'
    });
}

export async function CabinetCellList(params: any): Promise<any> {
    return network.post(cabinet.cabinetCellList, {
        data: params,
        requestType: 'form'
    });
}

export async function OpenCell(params: any): Promise<any> {
    return network.post(cabinet.openCell, {
        data: params,
        requestType: 'form'
    });
}

export async function UpdateCellIdle(params: any): Promise<any> {
    return network.post(cabinet.updateCellIdle, {
        data: params,
        requestType: 'form'
    });
}

export async function UpdateCellGlitch(params: any): Promise<any> {
    return network.post(cabinet.updateCellGlitch, {
        data: params,
        requestType: 'form'
    });
}

export async function CabinetCellSlaveList(params: any): Promise<any> {
    return network.post(cabinet.cabinetCellSlaveList, {
        data: params,
        requestType: 'form'
    });
}

export async function CabinetCellUpdateType(params: any): Promise<any> {
    return network.post(cabinet.cabinetCellUpdateType, {
        data: params,
        requestType: 'form'
    });
}

export async function BatchUpdateType(params: any): Promise<any> {
    return network.post(cabinet.batchUpdateType, {
        data: params,
        requestType: 'form'
    });
}

export async function CabinetSendCmd(params: any): Promise<any> {
    return network.post(cabinet.cabinetSendCmd, {
        data: params,
        requestType: 'form'
    });
}

export async function UpdateCabStatus(params: any): Promise<any> {
    return network.post(cabinet.setCabStatus, {
        data: params,
        requestType: 'form'
    });
}

export async function getCabinetLogList(params: any): Promise<any> {
    return network.post(cabinet.cabinetLogList, {
        data: params,
        requestType: 'form'
    });
}

export async function getCellTrackList(params: any): Promise<any> {
    return network.post(cabinet.cellTrackList, {
        data: params,
        requestType: 'form'
    });
}
